a=int(input())
while True:
    if a<10:
        if a<5:
            print(1)
            break
        elif a>5:
            print(0)
            break
